package Animal;

public class text1 {
    public static void main(String[] args) {
        Base base = new Sun();
        System.out.println(base.word);
        base.fun();
    }
}
class Base{
    String word="父类的属性";
    public void fun(){
        System.out.println("父类的fun");
    }
}
class Sun extends Base{
    String word="子类的属性";
    public void fun(){
        System.out.println("子类的fun");
    }
}
